<?php
namespace app\index\controller;
use think\Controller;

class Index extends Controller
{
    public function index()
    {
        if (!session('username')) {
            $this->redirect('admin/index/login');
        }else{
            return $this->fetch();
            function article()
            {
                return $this->view();
            }

            function diary()
            {
                return $this->fetch();
            }

            function link()
            {
                return $this->fetch();
            }

            function message()
            {
                return $this->fetch();
            }
        }
    }
}